package edu.hunau.cxb19.oop.class02;

/**
 *
 * @author hb
 *
 *         2020-02-25 15:51:26
 */
public class StudentTest {

	public void initStudent() {
		Student s1 = new Student();
		s1.major = "互联网";
		s1.grade = "2109级";
		// 从父类User中继承过来的属性
		s1.username = "haoren";
		s1.pwd = "250";
		s1.id = 1001;
		//new 关键字后面的类型称为运行时的类型
		//声明变量的类型称为编译类型。
		User u1 = new Student();
		
		 
		
		
	}
}
